#ifndef RAWIMAGE_H
#define RAWIMAGE_H

#include "RawOverlay.h"


class RawImage : public QByteArray
{
public:
    RawImage();
    RawImage( int width, int height, int channels);
    ~RawImage();
    bool create( int width, int height, int channels);
    int width()  const {
        return m_width;
    };
    int height()  const {
        return m_height;
    };
    int channels()  const {
        return m_channels;
    };
    uchar *bits() {
        return (uchar*)data();
    };
    uchar *scanLine(int row);
    void setAlpha(int x, int y, int alpha);
    QImage convertToQImage(bool cmyk = false , bool raw = false);
private:
    int m_width;
    int m_height;
    int m_channels;
};




#endif
